package com.ruoyi.restaurant.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.restaurant.mapper.SysHuiyuanMapper;
import com.ruoyi.restaurant.domain.SysHuiyuan;
import com.ruoyi.restaurant.service.ISysHuiyuanService;

/**
 * 会员数据Service业务层处理
 * 
 * @author ruoyi
 * @date 2022-05-26
 */
@Service
public class SysHuiyuanServiceImpl implements ISysHuiyuanService 
{
    @Autowired
    private SysHuiyuanMapper sysHuiyuanMapper;

    /**
     * 查询会员数据
     * 
     * @param huiyuanId 会员数据主键
     * @return 会员数据
     */
    @Override
    public SysHuiyuan selectSysHuiyuanByHuiyuanId(Integer huiyuanId)
    {
        return sysHuiyuanMapper.selectSysHuiyuanByHuiyuanId(huiyuanId);
    }

    /**
     * 查询会员数据列表
     * 
     * @param sysHuiyuan 会员数据
     * @return 会员数据
     */
    @Override
    public List<SysHuiyuan> selectSysHuiyuanList(SysHuiyuan sysHuiyuan)
    {
        return sysHuiyuanMapper.selectSysHuiyuanList(sysHuiyuan);
    }

    /**
     * 新增会员数据
     * 
     * @param sysHuiyuan 会员数据
     * @return 结果
     */
    @Override
    public int insertSysHuiyuan(SysHuiyuan sysHuiyuan)
    {
        return sysHuiyuanMapper.insertSysHuiyuan(sysHuiyuan);
    }

    /**
     * 修改会员数据
     * 
     * @param sysHuiyuan 会员数据
     * @return 结果
     */
    @Override
    public int updateSysHuiyuan(SysHuiyuan sysHuiyuan)
    {
        return sysHuiyuanMapper.updateSysHuiyuan(sysHuiyuan);
    }

    /**
     * 批量删除会员数据
     * 
     * @param huiyuanIds 需要删除的会员数据主键
     * @return 结果
     */
    @Override
    public int deleteSysHuiyuanByHuiyuanIds(Integer[] huiyuanIds)
    {
        return sysHuiyuanMapper.deleteSysHuiyuanByHuiyuanIds(huiyuanIds);
    }

    /**
     * 删除会员数据信息
     * 
     * @param huiyuanId 会员数据主键
     * @return 结果
     */
    @Override
    public int deleteSysHuiyuanByHuiyuanId(Integer huiyuanId)
    {
        return sysHuiyuanMapper.deleteSysHuiyuanByHuiyuanId(huiyuanId);
    }
}
